home *** CD-ROM | disk | FTP | other *** search
/ The VPRO Digital Guide 1994 / vpro.iso / vpro1 / overz.dir / 00054_MainSCORE Script.ls < prev    next >
Encoding:
Text File  |  1994-08-28  |  5.2 KB  |  191 lines

  1. on LocalStartMovie
  2.   global gWasAt, gComingFrom, gGoingTo, gClock, gClockLong, gPastLoc, gCurrentLoc, gLevels, mywindow
  3.   inivisiblizeHilites()
  4.   if voidp(gClock) then
  5.     LoadAllGlobals()
  6.   end if
  7.   CheckLocation()
  8.   go(chars(gWasAt, 1, 2))
  9.   updateStage()
  10.   BlinkPrevious()
  11.   SpinToCurrent()
  12.   BlinkCurrent()
  13. end
  14.  
  15. on CheckLocation
  16.   global gWasAt, gComingFrom, gGoingTo, gClock, gClockLong, gPastLoc, gCurrentLoc, gLevels
  17.   set ThirdChar to 0
  18.   repeat with i = 1 to 12
  19.     if chars(gWasAt, 1, 2) = item i of gClock then
  20.       set gWasAtLong to item i of gClockLong
  21.       set ThirdChar to char 3 of gWasAt
  22.       if ThirdChar > 0 then
  23.         set gPastLoc to item (ThirdChar * 12) + i - 12 of gLevels
  24.       else
  25.         set gPastLoc to "Home"
  26.       end if
  27.       exit repeat
  28.     end if
  29.   end repeat
  30.   repeat with i = 1 to 12
  31.     if chars(gComingFrom, 1, 2) = item i of gClock then
  32.       set gComingFromLong to item i of gClockLong
  33.       set ThirdChar to char 3 of gComingFrom
  34.       if ThirdChar > 0 then
  35.         set gCurrentLoc to item (ThirdChar * 12) + i - 12 of gLevels
  36.       else
  37.         set gCurrentLoc to "Home"
  38.       end if
  39.       exit repeat
  40.     end if
  41.   end repeat
  42. end
  43.  
  44. on BlinkPrevious
  45.   global gWasAt, gComingFrom, gGoingTo, gClock, gClockLong, gPastLoc, gCurrentLoc, gLevels
  46.   set the visible of sprite (char 3 of gWasAt + 38) to 1
  47.   repeat with count = 1 to 8
  48.     set the foreColor of sprite 37 to 6
  49.     updateStage()
  50.     MyDelay(1)
  51.     set the foreColor of sprite 37 to 255
  52.     updateStage()
  53.     MyDelay(1)
  54.   end repeat
  55.   set the visible of sprite (char 3 of gWasAt + 38) to 0
  56. end
  57.  
  58. on SpinToCurrent
  59.   global gWasAt, gComingFrom, gGoingTo, gClock, gClockLong, gPastLoc, gCurrentLoc, gLevels
  60.   inivisiblizeHilites()
  61.   puppetSound("WindMill")
  62.   updateStage()
  63.   set holder to chars(gComingFrom, 1, 2)
  64.   set test to 0
  65.   repeat while test = 0
  66.     go(the frame + 1)
  67.     if the frame = 37 then
  68.       go("AG")
  69.     end if
  70.     if the frameLabel = holder then
  71.       set test to 1
  72.     end if
  73.   end repeat
  74. end
  75.  
  76. on BlinkCurrent
  77.   global gWasAt, gComingFrom, gGoingTo, gClock, gClockLong, gPastLoc, gCurrentLoc, gLevels, gOffset
  78.   set the visible of sprite (char 3 of gComingFrom + 38) to 1
  79.   set CurrentHilite to the castNum of sprite (char 3 of gComingFrom + 38)
  80.   set TheyWereHere to the castNum of sprite 13
  81.   set ThisWasAtTop to the castNum of sprite 37
  82.   puppetSound(0)
  83.   CheckOffset()
  84.   repeat with i = 1 to 8
  85.     set the foreColor of sprite 37 to 6
  86.     updateStage()
  87.     MyDelay(1)
  88.     set the foreColor of sprite 37 to 255
  89.     updateStage()
  90.     MyDelay(1)
  91.   end repeat
  92.   duplicate(cast TheyWereHere, 133)
  93.   duplicate(cast ThisWasAtTop, 134)
  94.   if rollOver(43) then
  95.     go("RH")
  96.   end if
  97.   if rollOver(44) then
  98.     go("LH")
  99.   end if
  100. end
  101.  
  102. on spinToNext
  103.   global gWasAt, gComingFrom, gGoingTo, gClock, gClockLong, gPastLoc, gCurrentLoc, gLevels
  104.   puppetSound("WindMill")
  105.   updateStage()
  106.   set test to 0
  107.   set holder to chars(gGoingTo, 1, 2)
  108.   go(chars(gComingFrom, 1, 2))
  109.   if the frameLabel <> holder then
  110.     repeat while test = 0
  111.       go(the frame + 1)
  112.       if the frame = 37 then
  113.         go("AG")
  114.       end if
  115.       if the frameLabel = holder then
  116.         set test to 1
  117.       end if
  118.     end repeat
  119.   end if
  120.   puppetSound(0)
  121.   BlinkNext()
  122.   set FraNam to gGoingTo & "01"
  123.   if ((chars(FraNam, 1, 2) = "AG") or (chars(FraNam, 1, 2) = "BW")) and (integer(char 3 of FraNam) > 0) then
  124.     if chars(gGoingTo, 1, 2) = "AG" then
  125.       set FraNam to "AG30" & char 3 of gGoingTo
  126.       set gGoingTo to "AG" & char 3 of gGoingTo
  127.     else
  128.       if chars(gGoingTo, 1, 2) = "BW" then
  129.         set FraNam to "BW3" & zeroPad((integer(char 3 of gGoingTo) * 6) - 5)
  130.         set gGoingTo to "BW" & integer(char 3 of gGoingTo)
  131.       end if
  132.     end if
  133.   end if
  134.   set gWasAt to gComingFrom
  135.   set gComingFrom to gGoingTo
  136.   go(FraNam, chars(gGoingTo, 1, 2))
  137. end
  138.  
  139. on BlinkNext
  140.   global gWasAt, gComingFrom, gGoingTo, gClock, gClockLong, gPastLoc, gCurrentLoc, gLevels, gOffset
  141.   set the visible of sprite (char 3 of gGoingTo + 38) to 1
  142.   set CurrentHilite to the castNum of sprite (char 3 of gGoingTo + 38)
  143.   repeat with i = 1 to 8
  144.     set the foreColor of sprite 37 to 6
  145.     updateStage()
  146.     MyDelay(1)
  147.     set the foreColor of sprite 37 to 255
  148.     updateStage()
  149.     MyDelay(1)
  150.   end repeat
  151. end
  152.  
  153. on inivisiblizeHilites
  154.   repeat with i = 38 to 42
  155.     set the visible of sprite i to 0
  156.   end repeat
  157. end
  158.  
  159. on CheckOffset
  160.   global gWasAt, gComingFrom, gGoingTo, gClock, gClockLong, gPastLoc, gCurrentLoc, gLevels, gOffset
  161.   set GottaClick to the frameLabel
  162.   repeat with i = 1 to 12
  163.     if GottaClick = item i of gClock then
  164.       set gOffset to i
  165.       exit repeat
  166.     end if
  167.   end repeat
  168. end
  169.  
  170. on theOffSetThing
  171.   global gGoingTo, gOffset, gClock
  172.   set Chars1and2 to chars(the name of cast the castNum of sprite the clickOn, 1, 2)
  173.   set ThirdChar to char 3 of the name of cast the castNum of sprite the clickOn
  174.   repeat with i = 1 to 12
  175.     if Chars1and2 = item i of gClock then
  176.       set SecondOffset to i
  177.     end if
  178.   end repeat
  179.   set TotalOffset to gOffset + SecondOffset
  180.   if TotalOffset = 13 then
  181.     set TotalOffset to 12
  182.   else
  183.     set TotalOffset to abs((gOffset + SecondOffset + 11) mod 12)
  184.   end if
  185.   set gGoingTo to item TotalOffset of gClock & ThirdChar
  186.   inivisiblizeHilites()
  187.   puppetSprite(36, 0)
  188.   puppetSprite(37, 0)
  189.   spinToNext()
  190. end
  191.